home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / modula2 / 481 < prev    next >
Encoding:
Text File  |  1996-08-06  |  1.4 KB  |  39 lines

  1. Newsgroups: comp.lang.modula2
  2. Path: cix.compulink.co.uk!usenet
  3. From: mark_tbu@cix.compulink.co.uk ("Mark Morgan Lloyd ")
  4. Subject: Re: Interrupt Handlers in Topspeed Modula 2 V1.17
  5. Message-ID: <DozCpx.7B6@cix.compulink.co.uk>
  6. Organization: KDG Mobrey Telemetry
  7. References: <496207970wnr@harvey27.demon.co.uk>
  8. Date: Thu, 28 Mar 1996 13:41:57 GMT
  9. X-News-Software: Ameol
  10.  
  11. > There are several things that I can't seem to find explained very well:
  12. > If I want to write a keyboard interrupt handler, I will want to make it 
  13. > so that when my procedure returns, the registers are modified as if a 
  14. > call to the original handler had occured (at least most of the time, 
  15. > until the right keystroke(s) are entered) how do I do this??
  16.  
  17. I've done it by inline code to modify the stack.
  18.  
  19. > The First example modifies the interrupt vector table directly. If i 
  20. > want to use this method, how do I calculate the address for any given 
  21. > interrupt??
  22.  
  23. You don't. There's a DOS call to do this.
  24.  
  25. > And lastly: which of the above is the most practical/workable?? I would 
  26. > greatly appreciate a quick pointer in the right direction from someone 
  27. > who has tried this before :-)
  28.  
  29. I've done it in the past by hooking in a mixture of high-level and 
  30. assembler, but it was not nice. I don't suggest trying IOTRANSFER or 
  31. anything like that- it's not really designed for it.
  32.  
  33. Mark Morgan Lloyd
  34. mark_tbu@cix.compulink.co.uk
  35.  
  36. [Opinions above are the author's, not those of his employers or 
  37. colleagues]
  38.